Skip to content

cgroupsv2 supports linux.resources.unified from OCI spec#12884

Open
AmitPr wants to merge 2 commits intogoogle:masterfrom
modal-labs:amit/cgroupv2-unified
Open

cgroupsv2 supports linux.resources.unified from OCI spec#12884
AmitPr wants to merge 2 commits intogoogle:masterfrom
modal-labs:amit/cgroupv2-unified

Conversation

@AmitPr
Copy link
Copy Markdown
Contributor

@AmitPr AmitPr commented Apr 7, 2026

We noticed that setting linux.resources.unified to some value, such as { "memory.high": "..." } would work under runc, but not under runsc. According to the OCI spec, unified allows us to set any arbitrary cgroupsv2 property.

Whilst the systemd driver requires us to create a mapping between known cgroupv2 property labels and the systemd equivalent name, for cgroupsv2 this is a trivial change.

@google-cla
Copy link
Copy Markdown

google-cla bot commented Apr 7, 2026

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@aaltinaydev aaltinaydev self-assigned this Apr 9, 2026
@aaltinaydev aaltinaydev self-requested a review April 9, 2026 22:41
@aaltinaydev aaltinaydev removed their assignment Apr 9, 2026
copybara-service bot pushed a commit that referenced this pull request Apr 10, 2026
We noticed that setting `linux.resources.unified` to some value, such as `{ "memory.high": "..." }` would work under `runc`, but not under `runsc`. According to the [OCI spec](https://github.com/opencontainers/runtime-spec/blob/main/config-linux.md#unified), `unified` allows us to set any arbitrary cgroupsv2 property.

Whilst the `systemd` driver requires us to [create a mapping](https://github.com/opencontainers/runc/blob/main/docs/systemd.md#cgroup-v2) between known cgroupv2 property labels and the `systemd` equivalent name, for cgroupsv2 this is a trivial change.

FUTURE_COPYBARA_INTEGRATE_REVIEW=#12884 from modal-labs:amit/cgroupv2-unified c395abc
PiperOrigin-RevId: 897940632
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants